using System.Diagnostics;
using System.Runtime.CompilerServices;
using Nsb.Classes;
using Yoshi.Classes;

namespace Yoshi.Clusters
{
    [IgnoreNamespace]
    public abstract class ProfileBase : ProfileTruple
    {
        internal ProfileCluster ProfileCluster;

        public ProfileBase(ProfileCluster cluster)
        {
            ProfileCluster = cluster;
        }

        public ProfileData Data
        {
            get { return Master.Profile; }
        }

        public void Initialize()
        {
            Debug.Assert(Element != null, "Element != null");
            // ReSharper disable PossibleNullReferenceException
            Element.Empty();
            // ReSharper restore PossibleNullReferenceException
        }

        public abstract ProfileBase Build();
    }
}
